-- ----------------------------- 2023-08-11 add by zhoujq--------------begin

-- 建表语句
CREATE TABLE T_LIMS_GROUP( 
    ID NUMBER NOT NULL,
    GROUPNAME VARCHAR2(200)  NULL,
    PERSONID VARCHAR2(1000)  NULL,
    PERSONNAME VARCHAR2(1000)  NULL,
    CREATEDBYID VARCHAR2(36)  NULL,
    CREATEDBYNAME VARCHAR2(60)  NULL,
    CREATEDTIME DATE NULL,
    CREATEDBYORGID VARCHAR2(36)  NULL,
    CREATEDBYORGNAME VARCHAR2(270)  NULL
 );
COMMENT ON TABLE T_LIMS_GROUP IS '专业组';
COMMENT ON COLUMN T_LIMS_GROUP.ID IS '主键';
COMMENT ON COLUMN T_LIMS_GROUP.GROUPNAME IS '专业组';
COMMENT ON COLUMN T_LIMS_GROUP.PERSONID IS '人员id';
COMMENT ON COLUMN T_LIMS_GROUP.PERSONNAME IS '人员姓名';
COMMENT ON COLUMN T_LIMS_GROUP.CREATEDBYID IS '制单人编码';
COMMENT ON COLUMN T_LIMS_GROUP.CREATEDBYNAME IS '制单人名称';
COMMENT ON COLUMN T_LIMS_GROUP.CREATEDTIME IS '制单时间';
COMMENT ON COLUMN T_LIMS_GROUP.CREATEDBYORGID IS '制单人单位编码';
COMMENT ON COLUMN T_LIMS_GROUP.CREATEDBYORGNAME IS '制单人单位名称';

ALTER TABLE T_LIMS_GROUP ADD CONSTRAINT PK_LIMS_GROUP PRIMARY KEY (ID);

-- 旧版审计跟踪，跟踪配置变更语句

INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','ID','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','GROUPNAME','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','PERSONID','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','PERSONNAME','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYID','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYNAME','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDTIME','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYORGID','1',CURRENT_TIMESTAMP);
INSERT INTO T_CORE_AT_CONFIG_LINE (ID,CONFIGID,COLUMNID,AUDITTRAIL,CREATEDTIME) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYORGNAME','1',CURRENT_TIMESTAMP);
COMMIT;

-- 审计跟踪V2，跟踪配置变更语句

INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','ID','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','GROUPNAME','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','PERSONID','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','PERSONNAME','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYID','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYNAME','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDTIME','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYORGID','1');
INSERT INTO T_CORE_AUDIT_CONFIG_COLUMN (ID,CONFIGID,"COLUMN",AUDITABLE) VALUES (SEQ_CORE.NEXTVAL,'T_LIMS_GROUP','CREATEDBYORGNAME','1');
COMMIT;
CALL INSERTI18N('T_LIMS_GROUP.SERVICE_NAME', '专业组', '专业组', 'zh-CN', '专业组');
CALL INSERTI18N('T_LIMS_GROUP.ID', '专业组的主键', '主键', 'zh-CN', '主键');
CALL INSERTI18N('T_LIMS_GROUP.GROUPNAME', '专业组的专业组', '专业组', 'zh-CN', '专业组');
CALL INSERTI18N('T_LIMS_GROUP.PERSONID', '专业组的人员id', '人员id', 'zh-CN', '人员id');
CALL INSERTI18N('T_LIMS_GROUP.PERSONNAME', '专业组的人员姓名', '人员姓名', 'zh-CN', '人员姓名');
CALL INSERTI18N('T_LIMS_GROUP.CREATEDBYID', '专业组的制单人编码', '制单人编码', 'zh-CN', '制单人编码');
CALL INSERTI18N('T_LIMS_GROUP.CREATEDBYNAME', '专业组的制单人名称', '制单人名称', 'zh-CN', '制单人名称');
CALL INSERTI18N('T_LIMS_GROUP.CREATEDTIME', '专业组的制单时间', '制单时间', 'zh-CN', '制单时间');
CALL INSERTI18N('T_LIMS_GROUP.CREATEDBYORGID', '专业组的制单人单位编码', '制单人单位编码', 'zh-CN', '制单人单位编码');
CALL INSERTI18N('T_LIMS_GROUP.CREATEDBYORGNAME', '专业组的制单人单位名称', '制单人单位名称', 'zh-CN', '制单人单位名称');
CALL INSERTI18N('BASEMODULE.BASEDATA.PROGROUPS.MODAL.ADD', '新增', '新增', 'zh-CN', '新增');
CALL INSERTI18N('BASEMODULE.BASEDATA.PROGROUPS.TAB.BASE_INFO', '基本信息', '基本信息', 'zh-CN', '基本信息');
CALL INSERTI18N('BASEMODULE.BASEDATA.PROGROUPS.BUTTON.BUTTON', '按钮', '按钮', 'zh-CN', '按钮');
CALL INSERTI18N('BASEMODULE.BASEDATA.PROGROUPS.TIP.TIP', '提示框', '提示框', 'zh-CN', '提示框');
CALL INSERTI18N('BASEMODULE.BASEDATA.PROGROUPS.MODAL.MODAL', '对话框', '对话框', 'zh-CN', '对话框');

-- 创建菜单语句
INSERT INTO T_CORE_MENU (ID, MENUNAME, HREF, PARENTID, ORDERNO, ICON, MENUINITNAME)
VALUES ('20230811', '专业组', '/secure/basemodule/basedata/groups/page/edit-list', 'null', '20230811', '063.svg', '专业组');

INSERT INTO T_CORE_TABLE (ID, AUDITABLE, ATTACHMENT)
VALUES ('T_LIMS_GROUP', '0', '0');


COMMIT;

-- ----------------------------- 2023-08-11 add by zhoujq------------end